//
//  TNNewNotificationView.m
//  跑跑快销
//
//  Created by ylife on 14-5-4.
//  Copyright (c) 2014年 ylife. All rights reserved.
//

#import "TNNewNotificationView.h"

@implementation TNNewNotificationView

- (id)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        // Initialization code
        [self createView];
    }
    return self;
}

- (void)createView
{
    _contentTextView = [[UITextView alloc]initWithFrame:CGRectMake(5 , 7, 310, 180)];
    //添加圆角边框
    _contentTextView.layer.borderColor = [UIColor grayColor].CGColor;
    _contentTextView.layer.borderWidth =1.0;
    _contentTextView.layer.cornerRadius =5.0;
    
    [_contentTextView setFont:[UIFont systemFontOfSize:20]];
    _contentTextView.contentSize = CGSizeMake(300, 10);
    [self addSubview:_contentTextView];

    
    //画虚线
    UILabel *lable = [[UILabel alloc]initWithFrame:CGRectMake(5 ,137 , 320, 1)];
    [lable setTextColor:[UIColor grayColor]];
    [lable setFont:[UIFont systemFontOfSize:7]];   //默认17
    lable.text = @"- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ";
    [self addSubview:lable];
    
    _kindLable = [[UILabel alloc]initWithFrame:CGRectMake(5 , 138, 100, 49)];
//    _kindLable = [[UILabel alloc]init];
//    [_kindLable setBounds:CGRectMake(0, 131, 100, 49)];
    [_kindLable setTextAlignment:NSTextAlignmentCenter];
    [_kindLable setTintColor:[UIColor darkGrayColor]];
    [_kindLable setBackgroundColor:[UIColor blueColor]];
    [self addSubview:_kindLable];
    
    _selectButton = [[TNKindButton alloc]initWithFrame:CGRectMake(_contentTextView.frame.size.width - 120 + 5, 138, 120, 49)];
    [_selectButton setTitleColor:[UIColor orangeColor] forState:UIControlStateNormal];
    [_selectButton.titleLabel setFont:[UIFont systemFontOfSize:20]];
    [_selectButton setBackgroundColor:[UIColor redColor]];
    [self addSubview:_selectButton];
    
    }


@end
